<?php
// +---------------------------------------------------------------------+
// | OneBase    | [ WE CAN DO IT JUST THINK ]                            |
// +---------------------------------------------------------------------+
// | Licensed   | http://www.apache.org/licenses/LICENSE-2.0 )           |
// +---------------------------------------------------------------------+
// | Author     | Bigotry <3162875@qq.com>                               |
// +---------------------------------------------------------------------+
// | Repository | https://gitee.com/Bigotry/OneBase                      |
// +---------------------------------------------------------------------+

namespace app\common\model;

/**
 * 彩种模型
 */
class LotteryResult extends ModelBase
{



    /**
     * 连分类表
     */
    public function cate(){
        return $this->belongsTo('LotteryType','cate_id','id');
    }

    /**
     * 连分类表
     */
    public function lottery(){
        return $this->belongsTo('Lottery','lottery_id','id');
    }



//    public function  getNameAttr($value){
//
//        $lang=isset($_REQUEST['lang'])?$_REQUEST['lang']:'';
//        return   baidu_translate($value,$lang);
//
//
//    }



  
//  public function  getCateNameAttr(){
//      $lang=isset($_REQUEST['lang'])?$_REQUEST['lang']:'';
//      return   baidu_translate($this->cate['name'],$lang);
//
//
//    }

//    public function  getDescribeAttr($value){
//
//        $lang=isset($_REQUEST['lang'])?$_REQUEST['lang']:'';
//        return   baidu_translate($value,$lang);
//
//
//    }

//    public function  getContentAttr($value){
//        $lang=isset($_REQUEST['lang'])?$_REQUEST['lang']:'';
//        return   baidu_translate($value,$lang);
//
//    }

    /**
     * 时间自动完成
     */
    public function getCreateTimeAttr($value)
    {

        return date('Y-m-d H:i:s',$value);
    }


}
